#include "TcpServer.hpp"

void Usage(std::string argv)
{
    std::cout << argv << " port" << std::endl;
}

int main(int argc, char* argv[])
{
    Enable_Console_Log_Strategy();
    if(argc != 2)
    {
        Usage(argv[0]);
        exit(USAGE_ERR);
    }
    
    uint16_t port = std::stoi(argv[1]);

    std::unique_ptr<TcpServer> tsvr = std::make_unique<TcpServer>(port);
    tsvr->Start();
    tsvr->Run();
    return 0;
}